home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Assassins - Ultimate CD Games Collection 2
/
Assassins 2 - Ultimate Games No. 2 (1995)(Weird Science)[!][Amiga-CD32-CDTV].iso
/
board-games
/
mastermind_1.6
/
mastermind.doc
< prev
next >
Wrap
Text File
|
1993-12-04
|
8KB
|
217 lines
Program name: MasterMind V1.6
What it does: Implements the game of Master Mind
Author: Kamran Karimi
Written with: SAS/C 6.00
Source: Included
Machine: Amiga 1200
Run methode: From both WorkBench and Shell
Program status:You can run the program freely, but I retain the Copyright
to the program including the source and the executable form of it.
-----------------------------------------------------------------------------
Directory contents:
MasterMind <-- The program itself
MasterMind.doc <-- The file you are reading now
MasterMind.jl <-- this is a demo of how to use MasterMind. To use it,
first run MasterMind, then this program
MasterMind.jl.doc <-- a short explanaition of masterMind.jl
Source/MasterMind.c <-- source of mastermind
Source/misc.h <-- header used by MasterMind.c
Source/MasterMind.jl.c <-- source of MasterMind.jl
Source/MasterMind.jl.h <-- header used by MasterMind.jl.c
-----------------------------------------------------------------------------
What Is Master Mind?
Master Mind is a simple but interesting game: The Amiga chooses some
colors randomly and places them in a row. You have to guess not only
the colors, but also their places in the row. To do this, you guess
some colors and place them in a row as you see appropriate. When done,
the Amiga shows you the results by way of white and black circles.
A white circle shows that a color you have guessed is among the ones
the Amiga has chosen. A black circles says that one of the colors you
have guessed matches one of the Amiga's, more than that, it says that
the column of this color is the same as that of the Amiga's. Neither
white nor black circles don't say to which of your guessed colors they
belong. Also if a black circle appears for one of your guessed colors,
then no white circle will be shown for it.
You use these information to help a better guess in the next row, until
you either find the correct colors and their order, or you lose.
No timer is provided for this version so you can think as long as you
want.
Note that in this progam the Amiga does not choose duplicate colors. This
simplifies the game.
-----------------------------------------------------------------------------
This Implementation:
You can change many properties of the game including Board dimension
and the number of colors to guess among.
The board can be as small as having just one column and one row.
Maximum number of rows and columns depends on the Amiga the program is
running on. See 'What You Get...' for more information.
If number of rows exceeds 11 in PAL (8 in NTSC) the screen is changed into
an interlaced one. (unless you have OS2.0 or newer and suppress this with
'NOINTERLACE' in tool types or 'e' in command line).
The default configuration has 10 rows for PAL (8 for NTSC), 4 columns
and 6 colors to choose among. To configure the board, click on the
'Configure' gadget. three string gadgets appear, into which you can enter
number of rows, columns and number of colors to choose among. When done,
click on the 'Done!' gadget. Note than selecting a large screen in an
Amiga with little chip memory may lead to program termination, so consider
the amount of your chip RAM when configuring.
program compute the permutation of total colors and number of columns. row
number should be less than this.
Any configuration not appropriate from the program's point of view is
changed to defualt values.
To start playing, you should fill the first row, that is the lowest row
in the board. fill the row with colors. When done, click on the '<- Done'
gadget. You should not choose duplicate colors and all the row should be
filled. Considering these are done, the program shows you white and black
circles as appropriate and you can begin filling the next row up.
The game starts officially when you click '<- Done' the first time. After
that 'Quit Game' and 'Configure' gadgets become disabled, and 'Cheat!' and
'Abort!' are enabled.
If you are filling the top rows of the board, you may want to click the
right mouse button. This opens a window near the mouse pointer with the
color gadgets. You can drag this any where you like. Clicking right mouse
button another time, puts the color gadgets to their original place.
Another option is cheating, if you click on the 'Cheat!' gadget, one of the
colors the Amiga has chosen is shown, but not its position.
After the game has begun, you can terminate the current play by clicking
on the 'Abort!' gadget. After this, a window opens showing the correct
settings and you should close it to continue.
You lose a game when you fail to find the colors and their order in the
last row. In this case also, the window with correct color and order is
showed, which you should close before continuing.
If you win, you should click on the 'OK' gadget to continue.
Some text appears in the upper right corner of the screen. This may be
considered as help. Error texts are in red and accompanied by a screen beep.
What You Get If You Have...
OS1.2 or OS1.3:
In this case you have the basic game. You can choose among at most 12
colors. board dimentions can have up to 24 rows in PAL (18 rows in NTSC)
and 9 columns.
OS2.0:
You get a Public Screen with the name of MasterMind (if not suppressed
with 'CUSTOMSCREEN' in tool types or 'm' in command line).
The board can have up to 99 rows and 12 columns. If the number of rows
becomes more than 24 in PAL (18 in NTSC) or the number of columns becomes
greater than 9, an scrollable window is opened. This is reflected in the
screen name. You may not be able to use very large boards because of lack
of chip RAM.
OS2.0 and ECS:
Here the program tries to open a PAL screen on NTSC machines (if not
suppressed with 'NOPAL' in tool types or 'n' in command line).
OS3.0:
Nothing that the user can see, but OS3.0 graphics routines are used in
this case. As I don't have access to 3.0 includes, few 3.0-specific
features could be used.
ARGUMENTS:
To change configuration before starting the program, you may use command
line arguments (if started from CLI) or tool type arguments (if started
from WorkBench). To change the tool types, you should use 'Information'
or 'Info' from WorkBench menus on the icon of the program.
In Shell, type 'MasterMind ?' for a brief explanation of command line
arguments. In Workbench, all the arguments are present in the program
icon, but either set to default values or disabled by appending a ';' to
them (like ';CUSTOMSCREEM').
To change board columns:
In CLI: Enter: 'g' or 'G' followed immidiately with the number you
want. Example: g5.
In WorkBench: Type 'GUESS' and the number you like in tool types.
Example: GUESS=6.
Default: 4.
Minimum: 1.
Maximum: Machine dependent (9 or 12).
To change board rows:
In CLI: Enter 't' or 'T' fllowed immidiately with the number you
want. Example: T80.
In WorkBench: Type 'TRIES' and the number you like in tool types.
Example: TRIES=12.
Default: 10 for PAL, 8 for NTSC.
Minumum: 1.
Maximum: Machine dependent (24/18 or 99).
To change number of colors to choose among:
In CLI: Enter 'c' or 'C' followes immidiately with the number you
want. Example: c12.
In WorkBench: Type 'COLORS' and the number you like in tool types.
Example: COLORS=3.
Default: 6.
Minimum: 2.
maximun: 12.
To prevent opening a public screen:
(Ignored under 1.2 and 1.3)
In CLI: Enter 'm' or 'M'.
In WorkBench: Type 'CUSTOMSCREEN' in tool types.
Default: Opens a public screen.
To prevent the programm from opening an interlaced screen:
(Ignored under 1.2 and 1.3)
In CLI: Enter 'e' or 'E'.
In WorkBench: Type 'NOINTERLACE' in tool types.
Default: Uses interlace screen.
To prevent the program from opening a PAL screen in NTSC machines:
(Ignored under 1.2 and 1.3)
In CLI: Enter 'n' or 'N'.
In WorkBench: Type 'NOPAL' in tool types.
Default: tries to opens a PAL screen.
-----------------------------------------------------------------------------
My Address:
You can reach me at the following address:
Kamran Karimi
2,HassanAbad
HaghShenas str.
Navab str.
13599 - Tehran
Iran